/**
 * 文件名：EvidenceState.java
 *
 * 创建人：Elvin Zhao - 279152260@qq.com
 *
 * 创建时间：2019年1月2日 下午5:23:25
 *
 * 版权所有：FNII
 */
package com.z100h.supplychain.core;

/**
 * [描述信息：说明类的基本功能]
 *
 * @author Elvin Zhao - 279152260@qq.com
 * @version 1.0 Created on 2019年1月2日 下午5:23:25
 */
public enum StockoutState {

	WAITINGFORQUALITYINSPECTION("WAITINGFORQUALITYINSPECTION", "待质检"),

	WAITINGFORRECTIFICATION("WAITINGFORRECTIFICATION", "待整改"), WAITINGFORSTOCKOUT("WAITINGFORSTOCKOUT",
			"待出库"), FINISH("FINISH", "完成");

	private String type;

	private String name;

	private StockoutState(String type, String name) {
		this.type = type;
		this.name = name;
	}

	public String getType() {
		return type;
	}

	public void setType(String type) {
		this.type = type;
	}

	public String getName() {
		return name;
	}

	public void setName(String name) {
		this.name = name;
	}

	public static StockoutState get(String stockoutState) {
		switch (stockoutState) {
			case "WAITINGFORQUALITYINSPECTION":
				return WAITINGFORQUALITYINSPECTION;
			case "WAITINGFORRECTIFICATION":
				return WAITINGFORRECTIFICATION;
			case "WAITINGFORSTOCKOUT":
				return WAITINGFORSTOCKOUT;
			default:
				return FINISH;
		}
	}
}
